how to create a modal in javascript